

import 'package:flutter/cupertino.dart';

class StoreCommentProvider extends ChangeNotifier {



  String beginTime=DateTime.now().toString().substring(0,10);//开始时间

  String endTime=DateTime.now().toString().substring(0,10);//结束时间


  //评论信息 lsit储存
  List<dynamic> commentListArr=[];

  List<dynamic> get getCommentListArr => commentListArr;

  //门店评分
  num averageScore=0;

  //满意率
  num goodCommentRate=0;

  //搜索字符串
  String searchText='';

  //commentListArr 对应item的折叠状态
  List<bool> foldStatusArr=[];


  //当前用户点击了那一项

  int replyClickIndex;

  int get replyClickIndexGet=>replyClickIndex;

  //软键盘高度监听
  num keyboardHeight=0;








  commentListArrAdd(String data,int index){
    commentListArr[index]["commentReplyDOList"].add(
        {
          "id": null,
          "commentId": null,
          "reply": "$data",
          "creator": null,
          "updater": null,
          "ctime": null,
          "utime": null
        }
    );

    notifyListeners();


  }

  @override
  void notifyListeners() {
    // TODO: implement notifyListeners
    super.notifyListeners();
  }


  StoreCommentProvider({this.searchText,this.beginTime,this.endTime});

}